package com.neolix.daoGenerate;

import de.greenrobot.daogenerator.DaoGenerator;
import de.greenrobot.daogenerator.Entity;
import de.greenrobot.daogenerator.Schema;

public class MyClass {

    public static void main(String args[]) throws Exception {
        Schema schema = new Schema(1, "com.neolix.watch.dao");
//        Entity upload = schema.addEntity("Upload");
//        upload.addIdProperty();
//        upload.addStringProperty("text");
//
//
//        Entity city = schema.addEntity("City");
//        city.setTableName("City");
//        city.addStringProperty("name");

        Entity remindEvent = schema.addEntity("RemindEvent");
        remindEvent.addIdProperty().autoincrement();
        remindEvent.addIntProperty("eventID").notNull();
        remindEvent.addStringProperty("content").notNull();
        remindEvent.addDateProperty("dateTime");
        remindEvent.addDateProperty("createDateTime");

        new DaoGenerator().generateAll(schema, "E:\\work\\neolixWatch\\NeolixWatch\\watch\\src-gen");
    }
}
